package com.robertlundberg.chess;

import java.util.List;
import java.util.Random;

public class ChessMain {
	
	public static void main(String args[])
	{
		Board B = new Board();
		List GeneratedMoves;
		Random generator = new Random();
		B.PrintBoardWPieceListPositions();	
		System.out.println("");		
		B.PrintBoardWPieceValues();
		
		MoveGenerator MG = new MoveGenerator(B);
		GeneratedMoves = MG.GenerateMoves();
		System.out.println("");
		for(int i=0;i < GeneratedMoves.size();i++)
		{
			System.out.printf("(%d)",(Integer)GeneratedMoves.get(i));
		}
		for(int i=0;i < GeneratedMoves.size();i++)
		{
			System.out.printf("(%d-%d)",Move.GetFromSquare((Integer)GeneratedMoves.get(i)),Move.GetToSquare((Integer)GeneratedMoves.get(i)));
		}		
		//System.out.printf("\n%d",B.MakeMove((Integer)GeneratedMoves.get(generator.nextInt(GeneratedMoves.size()))));		
		
		System.out.println();
		//System.out.println(Diagnostics.miniMax(MG,B, 1));
		B.MakeMove((Integer)GeneratedMoves.get(1));
		
		B.UnMakeMove();
		
		B.PrintBoardWPieceListPositions();
		
		
		
	}
	
}
